'use strict';

const Controller = require('egg').Controller;

class HomeController extends Controller {
    async index() {
        const {app, ctx, config, service} = this;
        console.log('------home')
        /*console.log(app); https://test-crm-api.solargenomics.com/
        console.log(ctx);*/
        // 接收get 参数
        console.log(ctx.params)
        console.log('------')
        //ctx.body = 'hi, egg';
        ctx.body = {
            code: '0000',
            msg: '成功-get',
            data: {
                pageNo: 1,
                pageSize: 20,
                total: 100,
                datas: [
                    {
                        id: '1234',
                        name: 'lx',
                    }
                ]
            }
        };
    }
}

module.exports = HomeController;
